[IA64] kexec: Only map PAL when making EFI, PAL or SAL calls
authorIsaku Yamahata <yamahata@valinux.co.jp>
Tue, 22 Jul 2008 03:15:02 +0000 (12:15 +0900)
committerIsaku Yamahata <yamahata@valinux.co.jp>
Tue, 22 Jul 2008 03:15:02 +0000 (12:15 +0900)
commit59dc86e4eb4d43a114f48965e55adfd6e0b40c2c
tree4aa95517367b2b706c251c29d9ab6ce2fb9b1b8b
parent8c2d0ddcc54b1523938bc893d726a036497cc0cf
[IA64] kexec: Only map PAL when making EFI, PAL or SAL calls

Move PAL code from the Xen identity mapped region to the
EFI identity mapped region, which overlaps with guest virtual space.

Make sure that PAL memory is only pinned into the TLB when making
EFI, PAL or SAL calls.

This seems to be nice as it provides a symmetrical approach to
mapping an unmapping pal code.

However it would be just as safe, and arguably simpler just to map
the PAL code (once?) when the EFI RR is active - for instance very
early on in boot, or when calling XEN_EFI_RR_ENTER. In other words,
unpining is XEN_EFI_RR_LEAVE shouldn't be neccessary, as the EFI RR
should protect the memory from unwanted accesses by guests (or
the hypevisor for that matter).

This patch is mostly the work of Yamahata-san.

Cc: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Simon Horman <horms@verge.net.au>
xen/arch/ia64/linux-xen/efi.c
xen/arch/ia64/linux-xen/mca_asm.S
xen/arch/ia64/linux-xen/smpboot.c
xen/arch/ia64/vmx/vmx_entry.S
xen/arch/ia64/vmx/vmx_phy_mode.c
xen/arch/ia64/vmx/vmx_vcpu.c
xen/arch/ia64/xen/xenasm.S
xen/include/asm-ia64/linux-xen/linux/efi.h
xen/include/asm-ia64/vmx_vcpu.h